package com.itheima.view.views;

import javax.swing.*;

public class JCheckBoxExample extends JFrame {
    public JCheckBoxExample() {
        super("复选框");
        Favorite favorite = new Favorite();
        this.add(favorite);//添加复写框对象到JF窗口中
        this.pack();
        this.setVisible(true);

    }

    public static void main(String[] args) {
        JCheckBoxExample jcbe=new JCheckBoxExample();
        jcbe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    }
}
